import {useRoute} from '@react-navigation/native';
import React, {useEffect} from 'react';
import {View, Text} from 'react-native';
import {getSongListApi} from '../../api/home';
const SongList = () => {
  const route = useRoute();
  useEffect(() => {
    async function get() {
      try {
        let res = await getSongListApi({id: route.params.id});
        let data = await res.json();
        console.log(data);
      } catch (e) {
        console.log(e);
      }
    }
    get();
  }, []);
  return (
    <View>
      <Text>SongList{route.params.id}</Text>
    </View>
  );
};

export default SongList;
